﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.IO;
using System.Text;


namespace UpdateError
{
    class Program
    {
        static void Main(string[] args)
        {
            string curentFolder = AppDomain.CurrentDomain.BaseDirectory;
            string[] files = System.IO.Directory.GetFiles(curentFolder);
            files.Where(f => f.EndsWith(".Error", StringComparison.InvariantCultureIgnoreCase)).ToList().ForEach(file =>
            {
                System.IO.File.Move(file, file.TrimEnd(".Error".ToCharArray()));
            });
        }
    }
}
